package top.scsoul.pas.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import top.scsoul.pas.bean.XhrResponse;
import top.scsoul.pas.entity.Role;
import top.scsoul.pas.service.RoleService;

import java.util.List;
@Slf4j
@Controller
public class RoleController {
    @Autowired
    RoleService roleService;

    @ResponseBody
    @RequestMapping("api/roleList")
    public XhrResponse roleList() {
        return XhrResponse.success(roleService.roleList());
    }
}
